package com.yh.workbill.login;

import android.app.Application;

import androidx.annotation.NonNull;
import androidx.lifecycle.AndroidViewModel;
import androidx.lifecycle.LiveData;
import androidx.lifecycle.MutableLiveData;

public class LoginViewModel extends AndroidViewModel {

    public MutableLiveData<String> phone;
    public MutableLiveData<String> pwd;

    public LoginViewModel(@NonNull Application application) {
        super(application);
    }

    public MutableLiveData<String> getPhone() {
        if (phone == null) {
            phone = new MutableLiveData<String>();
            phone.setValue("");
        }
        return phone;
    }

    public MutableLiveData<String> getPwd() {
        if (pwd == null) {
            pwd = new MutableLiveData<String>();
            pwd.setValue("");
        }
        return pwd;
    }
}
